<template>
  <div class="home">
    <div class="home-btn">
      <van-button type="primary" size="large"
                  style=" color: #0FCB97;
                  font-size: 24px;
                  font-weight: 600;
                  height:100%;
                  background: #ffffff;
                  border-color: rgb(132, 225, 174);"
                  @click="gotoPagesFunc">一键登录系统
      </van-button>
    </div>
  </div>
</template>

<script>
export default {
  name: 'Index',
  components: {},
  data() {
    return {}
  },
  methods: {
    gotoPagesFunc() {
      let userType = JSON.parse(sessionStorage.getItem('userInfo')).userType
      // 患者端 首页跳转
      if (userType == 1) {
        this.$router.push({path: '/patientHome'})
      } else {
        this.$router.push({path: '/home'})
      }
    }
  }
}
</script>

<style scoped>
.home {
  position: relative;
  width: 100vw;
  height: 100vh;
  margin-bottom: 0 !important;
  background: url("") no-repeat center center;
  background-size: cover;
}

.home-btn {
  position: absolute;
  top: 83%;
  left: 52%;
  transform: translateX(-50%);
  width: 300px;
  height: 60px;
}
</style>
